<template>
    <div>
        <form action="/login" method="POST" @submit.prevent="SendLogin">
            <fieldset>
                <legend>登录</legend>
                <br>
                <div>
                    <label for="username">用户名：</label>
                    <input id="username" type="用户名" v-model="person.username">
                </div>
                <br>
                <div>
                <label for="password">密码：</label>
                    <input id="password" type="password" v-model="person.password">  
                </div>
                <br>
                <input type="submit" value="登录">
            </fieldset>
        </form>

    </div>
</template>


<script>
export default {
    // eslint-disable-next-line vue/multi-word-component-names
    name: "Login",
    data() {
        return {
            person: {
                username:"",
                password:""
            }
        }
    },
    methods: {
        SendLogin: function() {
            console.log(this.person)
        }
    }
}
</script>